package com.tyros.storage.config.property;

import com.tyros.storage.enums.StorageType;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.NestedConfigurationProperty;
import org.springframework.stereotype.Component;

/**
 * @author zhangshuaiyin
 * @date 2022/2/20 12:37
 */
@Data
@Component
@ConfigurationProperties("tyros.storage")
public class StorageProperties {

    private StorageType type = StorageType.ALI_YUN;

    @NestedConfigurationProperty
    private LocalProperties local;

    @NestedConfigurationProperty
    private AliYunOssProperties ali;
}
